#ifndef __GATEWAY_H__
#define __GATEWAY_H__
#include "Service.h"

/**
* Gateway to ethernet network. 
* - Broadcasts all messages send internally to ethernet
* - Listens to ethernet broadcasts and broadcasts those messages internally
*/
class IEthernet;

class Gateway : public Service{
public:
	Gateway(IArduino& arduino, MessageRouter& router, IEthernet& eth, ILogger& logger);
	virtual void onMessage(const String& msg);
	virtual void tick(long milliseconds);
	virtual bool isInfrastructure() const;
private:
	IEthernet& ethernet_;
};

#endif